//
//  Constants.h
//  RMTShell
//
//  Created by Shappy Say on 5/3/13.
//  Copyright (c) 2013 HSBC. All rights reserved.
//

#define APP_TITLE @"RM Tablet"

#define StandaloneMode @"false"

#define NATIVE_APP_VERSION_HTTP_HEADER_FIELD @"native-app"
#define NATIVE_APP_DEVICE_TYPE_HTTP_HEADER_FIELD @"device-type"
#define NATIVE_APP_DEVICE_ID_HTTP_HEADER_FIELD @"device-id"
#define NATIVE_APP_DEVICE_STATUS_HTTP_HEADER_FIELD @"device-status"
#define secureToken @"d0a86970cfb52b2e2f4749943ee990b3e941a26a9bff998ef564ed9d2a8d5006"
#define error_code_p001                 @"P001"
// generic error code
#define error_code_p002                 @"P002"

#define NATIVE_APP_VERSION_HTTP_HEADER_VALUE @"%@-%@-v%@"
#define NATIVE_APP_DEVICE_TYPE_HTTP_HEADER_VALUE @"%@-OS%@"

#define CONFIG_FILE_DOWNLOAD_LOC                @"https://hbapp2g:hbapp2g@www.ap464.p2g.netd2.hsbc.com.hk/P2GTheme/themes/html/BDE_HBAP_MOBILE/RMTEntityList1.0.xml"
#define CHECK_SUM_DOWNLOAD_LOC                  @"https://hbapp2g:hbapp2g@www.ap464.p2g.netd2.hsbc.com.hk/P2GTheme/themes/html/BDE_HBAP_MOBILE/RMTChecksum1.0.xml"
//#define CONFIG_FILE_DOWNLOAD_LOC                @"http://172.20.10.6/RMTEntityList1.0.xml"
//#define CHECK_SUM_DOWNLOAD_LOC                  @"http://172.20.10.6/RMTChecksum1.0.xml"


//uat
//#define CONFIG_DOWNLOAD_LOC @"https://120.24.55.7/ota/config/red-uat/STAConfig-ios.txt"
//production
//#define CONFIG_DOWNLOAD_LOC @"https://120.24.70.17/ota/config/red-hbcn-prod/STAConfig-ios.txt"
//test
//#define CONFIG_DOWNLOAD_LOC @"https://120.24.55.7:8449/download/beta.txt"
//#define CONFIG_DOWNLOAD_LOC @"https://www1.qualityassurance.fileupload.asiapacific.hsbc.com/imageAttach/forMobileTeam/STA/STAConfig-ios.txt"

//#define CONFIG_DOWNLOAD_LOC @"http://reddownload.oss-cn-shenzhen.aliyuncs.com/UAT/Test/STAConfig-ios.txt"
#define CONFIG_DOWNLOAD_LOC @"https://120.24.55.7:8449/download/beta.txt"

#define CONFIG_FILE_DOWNLOAD_PERIOD (1)

#define NON_HTTP_SCHEME @"hsbc://"

#define NATIVE_APP_KEYCHAIN_SERVICE_NAME        @"HSBC-KEYCHAIN-SERVICE-NAME"
#define NATIVE_APP_KEYCHAIN_DATA_UUID           @"HSBC-APP-UUID"

#define CNS_PLUGIN_URL @"url"
#define CNS_PLUGIN_DATA @"data"
#define CNS_PLUGIN_METHOD @"method"
#define CNS_USER_NAME @"username"
#define CNS_USER_PASSWORD @"userpassword"
#define CNS_SESSION_ID @"sessionid"
#define CNS_LOGON_TIME @"logontime"
#define CNS_DOMAIN @"domain"
#define CNS_OFFLINE @"offlineauthentication"
#define CNS_SHOW_CANCEL_BUTTON @"showcancelbutton"

#define CNS_LOGON_TITLE @"title"
#define CNS_LOGON_SUBTITLE @"subtitle"

#define CNS_WEB_CACHE @"webviewcache"

#define CNS_LAN_RECT CGRectMake(0, 0, 1024, 748)
#define CNS_POR_RECT CGRectMake(0, 0, 768, 1004)

// successful status code
#define CNS_STATUS_SUCC                 @"200"
// timeout error code, triger by client
#define CNS_STATUS_NETWORK_FAIL_ERR     @"P001"
// generic error code
#define CNS_STATUS_NETWORK_GENERIC_ERR  @"P002"
// hook api fail to execute error code
#define CNS_STATUS_HOOKAPI_ERR          @"P003"


//general error
#define CNS_STATUS_APP_GENERIC_ERR      @"E001"
// successful status code
#define region_webview_status_code_0000          @"0000"
// timeout error code
#define region_webview_status_code_p001          @"P001"
// generic error code
#define region_webview_status_code_p002          @"P002"
// hook api fail to execute error code
#define region_webview_status_code_p003          @"P003"
// network can not reachable error code
#define region_webview_status_code_p004          @"P004"

#define http_con_default_timeout        60.0


#define proxy_connect                               @"proxyConnect"
#define proxy_connect_logon                         @"proxyConnectLogon"
#define proxy_json_connect                          @"proxyJSONConnect"\

#define PLATFORM_KEY @"platform"
#define PLATFORM @"I"
#define DEVICE_TYPE_KEY @"devtype"
#define DEVICE_TYPE_MOBILE @"M"
#define DEVICE_TYPE_TABLET @"T"

// Error Code
#define COMPARE_CHECKSUM_ERROR  @"ERROR_0001"
